package com.benz.project.pvm.http.vo;

import java.util.Date;
import java.util.HashMap;
import java.util.Map;

public class ResponseEntity {

    private String  message = "操作成功";
    private Date timestamp;
    private int status = 200;
    private String error;
    private Long useTime;

    private Map<String, Object> data;

    public String getMessage() {
        return message;
    }

    public void setMessage(String message) {
        this.message = message;
    }

    public Date getTimestamp() {
        return timestamp;
    }

    public void setTimestamp(Date timestamp) {
        this.timestamp = timestamp;
    }

    public int getStatus() {
        return status;
    }

    public void setStatus(int status) {
        this.status = status;
    }

    public String getError() {
        return error;
    }

    public void setError(String error) {
        this.error = error;
    }

    public Long getUseTime() {
        return useTime;
    }

    public void setUseTime(Long useTime) {
        this.useTime = useTime;
    }

    public Map<String, Object> getData() {
        return data;
    }

    public void setData(Map<String, Object> data) {
        this.data = data;
    }

    public void setData(String key, Object dataObject){
        Map<String, Object> data = new HashMap<>(  );
        data.put( key, dataObject );
        this.data = data;
    }
}
